import request from '@/utils/request';

// 积分规则查看
export function getPointsRuleInfo(data: any) {
    return request({
        url: '/scrm-api/console/member/points/rule/info',
        method: 'post',
        data
    });
}

// 积分规则设置
export function setPointsRuleInfo(data: any) {
    return request({
        url: '/scrm-api/console/member/points/rule/set',
        method: 'post',
        data
    });
}

// 积分规则-特殊商品设置
export function setPointsProduct(data: any) {
    return request({
        url: '/scrm-api/console/member/points/appoint/product/set',
        method: 'post',
        data
    });
}

// 积分规则-商品列表
export function getPointsProductList(data: any) {
    return request({
        url: '/scrm-api/console/member/points/appoint/product/list',
        method: 'post',
        data
    });
}

// 积分规则-特殊商品删除
export function delPointsProduct(data: any) {
    return request({
        url: '/scrm-api/console/member/points/appoint/product/del',
        method: 'post',
        data
    });
}

// 积分变动类型
export function getBusinessType(data?: any) {
    return request({
        url: '/scrm-api/console/member/points/business/type',
        method: 'post',
        data
    });
}

// 客户管理-设置达人设置
export function setDarenRuleInfo(data?: any) {
    return request({
        url: '/scrm-api/console/member/daren/points/rule/set',
        method: 'post',
        data
    });
}

// 客户管理-获取达人设置
export function getDarenRuleInfo(data?: any) {
    return request({
        url: '/scrm-api/console/member/daren/points/rule/info',
        method: 'post',
        data
    });
}

// 达人订单转换记录
export function getDarenConvertList(data?: any) {
    return request({
        url: '/scrm-api/console/member/daren/order/convert/list',
        method: 'post',
        data
    });
}

/**
 * @description: 成长值变动类型
 * @param {any} data
 * @return {*}
 */
export function getBusinessGrowthType(data?: any) {
    return request({
        url: '/scrm-api/console/member/growth/business/type',
        method: 'post',
        data
    });
}
